public class Test {
    public static void main(String[] args) {
        int[] array = {10,5,12,13,6};

        BinarySearchTree binarySearchTree = new BinarySearchTree();
        for (int x : array) {
            binarySearchTree.insert(x);
        }
        BinarySearchTree.TreeNode search = binarySearchTree.search(12);
        System.out.println(search.val);
    }
}
